let PersonalRegister={
    path:'/Register',
    name:'Register',
    component:()=>import('../../../views/Personal/Register/Home.vue'),
    redirect: '/Register/PersonalRegister',
    children:[
        {
            path:'PersonalRegister',
            name:'PersonalRegister',
            component:()=>import('../../../views/Personal/Register/Personal.vue'),
            beforeEnter: (to, from, next) => {
                if(from.name=='RegisterHome'){
                    next();
                }else if(from.name=='CompanyRegister'){
                    next()
                }else if(sessionStorage.getItem('fName') && sessionStorage.getItem('fName')=='PersonalRegister'){
                    next()
                }
              }
        },
        {
            path:'CompanyRegister',
            name:'CompanyRegister',
            component:()=>import('../../../views/Company/Register/Register.vue'),
            beforeEnter: (to, from, next) => {
                if(from.name=='RegisterHome'){
                    next();
                }else if(from.name=='PersonalRegister'){
                    next()
                }else if(sessionStorage.getItem('fName') && sessionStorage.getItem('fName')=='CompanyRegister'){
                    next()
                }
              }
        }
    ]
}
export default PersonalRegister